package com.dick.base.dto;

import com.dick.base.model.BaseDictValue;
import lombok.Data;

import java.util.LinkedList;
import java.util.List;

@Data
public class DictValueTreeNode extends BaseDictValue {

    public DictValueTreeNode() {

    }

    public DictValueTreeNode(BaseDictValue dictValue) {
        this.setId(dictValue.getId());
        this.setCode(dictValue.getCode());
        this.setCodeValue(dictValue.getCodeValue());
        this.setCodeLabel(dictValue.getCodeLabel());
        this.setCreateTime(dictValue.getCreateTime());
        this.setUpdateTime(dictValue.getUpdateTime());
        this.setParentId(dictValue.getParentId());
        this.setSortCode(dictValue.getSortCode());
        this.setDeleted(dictValue.getDeleted());
    }

    private List<BaseDictValue> children = new LinkedList<>();
}
